﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ExamPaerDisp.aspx.cs" Inherits="Web.ExamPaerDisp" EnableViewState="false" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title>打印试卷</title>
<style type="text/css">
body,div,h1,h3,h5,p,dl,dt,dd,ul,ol,li,img {padding:0;margin:0;font-size:3.5mm;}
body {font-family:"宋体", Verdana, Geneva, sans-serif;color:#000000;font-size:3.5mm;line-height:160%; background:#000000;}
h3,h5 {font-family:"黑体";}
li {list-style:none;}
img {border:none;}
.wrap {width:150mm;margin:0 auto;height:225mm;background:#000000;clear:both;}
.wrap .content{ background-color:#ffffff;clear:both;}
#TempList{width:150mm;margin:auto;}
.title {height:20mm;font-size:5mm;font-weight:normal;text-align:center;letter-spacing:2mm;}
.title span,.title strong {display:block;}
.title strong {height:15mm;line-height:15mm;font-family:"黑体";font-size:7mm;letter-spacing:8mm;}
.info {width:144mm;padding:0 3mm;}
.info li {float:left;display:inline;}
.info li.school {width:47mm;}
.info li.name {width:33mm;}
.info li.number {width:64mm;}
.ill {border:0.2mm solid #000000;clear:both;margin-top:3mm;}
.ill .ill-t {height:7mm;line-height:7mm;border-bottom:0.1mm solid #000000;padding:0 3mm;}
.ill .ill-c {padding:2mm;}
.blockleft {float:left;width:8mm;}
.blockright {float:right;width:142mm;}
.block {clear:both;}
p img {max-width:500px;width:expression((this.width>500)?500:this.width);}
.isclear{clear:both; height:0px;}
#tool{ background-color:#ffffff;width:150mm;margin:0 auto;}


</style>
<script type="text/javascript" src="js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="js/jquery.jeditable.mini.js"></script>
<script type="text/javascript" src="js/formulae.js"></script>

</head>

<body>


<div id="main">
<div id="tool"><form action="ExamPaerPring.aspx" method="post" enctype="multipart/form-data">
<input id="ExamPaperId" name="ExamPaperId" type="hidden" value="<%=ExamPaperId %>" />
<input id="DisAnswer" name="DisAnswer" type="checkbox" value="yes" />显示答案<input id="Submit1" type="submit" value="导出到Word" /></form></div>
<div id="page1" class="wrap">
<div class="content">
<div id="top">
  <h1 class="title"><span>2009北京市高级中等学校招生试卷</span><strong><%=ExamPaper_Info.Name %></strong></h1>
  <ul class="info"><li class="school">学校___________________</li><li class="name">姓名___________</li><li class="number">准考证号___________________________</li></ul>
  <div class="ill">
    <h5 class="ill-t">考生须知</h5>
    <div class="ill-c">1.<br />2.<br />3.<br />4.<br />5.</div>
  </div>
</div>
</div>
</div>
</div>
<form runat="server" id="form1">
<asp:Label ID="TempList" runat="server"></asp:Label></form>
<script type="text/javascript">
var i=1;
var pageheight=225*2.8;;
var tpage,tfill,tcontent;
$(document).ready(function() {
    $(".Answer").hide();
    tpage = $("#page1");
    tcontent = $("#page1 .content");
    $("#TempList .block").each(function() {
        MoveBlock($(this));
    })
    $("#DisAnswer").click(function() {
        if ($("#DisAnswer").attr("checked")) {
            $(".Answer").show();
        }
        else {
            $(".Answer").hide();
        }
    })
    function MoveBlock(str) {
        if (str.height() < tpage.height() - tcontent.height()) {
            str.clone().appendTo(tcontent).editable('edittablesave.aspx', {
                type: 'textarea',
                tooltip: "双击进行编辑",
                event: "dblclick",
                submit: '确定',
                cancel: '取消'
            });
            str.remove();
        }
        else {
            if (str.height() < tpage.height()) {
                NewPage();
                MoveBlock(str);
            }
        }
    }

    function NewPage() {
        i++;
        $("#main").append("<div id='page" + i + "' class='wrap clearfix2'><div class='content clearfix2'></div></div>");
        tpage = $("#page" + i + "");
        tcontent = $("#page" + i + " .content");
    }

    $('.title span').editable('edittablesave.aspx', {
        type: 'textarea',
        tooltip: "单机进行编辑",
        submit: '确定',
        cancel: '取消'
    });
    $('.title strong').editable('edittablesave.aspx', {
        type: 'textarea',
        tooltip: "单机进行编辑",
        submit: '确定',
        cancel: '取消'
    });
    $(".ill-c").editable('edittablesave.aspx', {
        type: 'textarea',
        tooltip: "单机进行编辑",
        submit: '确定',
        cancel: '取消'
    });
});
</script>

</body>
</html>